<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <script type="text/javascript" src="../js/vue.js"></script>
    <script type="text/javascript" src="../js/jquery.min.js"></script>
    <script type="text/javascript" src="../js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="../css/bootstrap.min.css">
    <title>Document</title>

    <style>
        .thin {
            font-weight: 200;
        }
        
        .red {
            color: red;
        }
        
        .blue {
            color: blue;
        }
        
        .italic {
            font-style: italic;
        }
    </style>
</head>

<body>

    <div id="app">
        <!-- <h1 class="thin red italic">一级标题</h1> -->

        <!-- <h1 :class="['red','thin','italic']">一级标题</h1> -->

        <!-- <h1 :class="['thin','italic',fontColor=='red'?'red':'blue']">一级标题</h1> -->

        <!-- <h1 :class="['thin', 'italic', {'red':fontColor=='red'}]">一级标题</h1> -->

        <!-- <h1 :class="{thin:true, italic:true, red:true}">一级标题</h1> -->

        <h1 :class="styleObj">一级标题</h1>

    </div>

    <script>
        var vm = new Vue({
            el: "#app",
            data: {
                fontColor: 'reds',
                styleObj: {
                    thin: true,
                    italic: true,
                    red: true
                }
            },
            methods: {

            }
        });
    </script>

</body>

</html>